package com.freight.order.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.freight.base.dto.AreaDto;
import com.freight.order.dto.CityDto;
import com.freight.order.dto.CompanySearchOrderDto;
import com.freight.order.dto.DriverGoodsDto;
import com.freight.order.dto.SearchOrderDto;
import com.freight.order.entity.OrderOrder;
import com.freight.order.entity.OrderTrack;
import com.freight.order.vo.*;
import com.freight.user.dto.CompanyDto;
import com.freight.user.dto.DriverDto;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * 订单详情信息数据处理层
 *
 * @author huyingtai
 */
public interface OrderVoMapper extends BaseMapper<OrderVo> {

    List<MobileTrackVo> getMobileTrack(Long orderId);

    List<OrderTrack> getOrderTrack();

    /**
     * @param page
     * @param userId
     * @return
     */
    Page<DriverOrderCompanyVo> getDriverOrderCompanyInfo(Page<DriverOrderCompanyVo> page,
                                                         @Param("userId") Long userId);

    /**
     * @param orderId
     * @return
     */
    OrderVo getOrderInfoVo(@Param("orderId") Long orderId);



    /**
     * @param page
     * @param userId
     * @param searchOrderDto
     * @return
     */
    Page<OrderVo> getCompanyOrderVoByState(Page<OrderVo> page, @Param("userId") Long userId,
                                           @Param("searchOrderDto") CompanySearchOrderDto searchOrderDto);


    /**
     * @param page
     * @param searchOrderDto
     * @return
     */
    Page<OrderVo> getAdminOrderVoByState(Page<OrderVo> page,
                                           @Param("searchOrderDto") SearchOrderDto searchOrderDto);


    /**
     * @param page
     * @param userId
     * @param orderStates
     * @return
     */
    Page<OrderVo> getDriverOrderVoByState(Page<OrderVo> page, @Param("userId") Long userId,
                                          @Param("orderStates") String[] orderStates);


}